"""
__State2ProcDef_MDL.py_____________________________________________________

Automatically generated AToM3 Model File (Do not modify directly)
Author: gehan
Modified: Fri Jul 11 14:18:06 2014
___________________________________________________________________________
"""
from stickylink import *
from widthXfillXdecoration import *
from MatchModel import *
from ApplyModel import *
from Element import *
from State import *
from PortType import *
from Def import *
from ProcDef import *
from paired_with import *
from match_contains import *
from apply_contains import *
from graph_Def import *
from graph_paired_with import *
from graph_PortType import *
from graph_ApplyModel import *
from graph_MatchModel import *
from graph_apply_contains import *
from graph_match_contains import *
from graph_ProcDef import *
from graph_Element import *
from graph_State import *
from ATOM3Enum import *
from ATOM3String import *
from ATOM3BottomType import *
from ATOM3Constraint import *
from ATOM3Attribute import *
from ATOM3Float import *
from ATOM3List import *
from ATOM3Link import *
from ATOM3Connection import *
from ATOM3Boolean import *
from ATOM3Appearance import *
from ATOM3Text import *
from ATOM3Action import *
from ATOM3Integer import *
from ATOM3Port import *
from ATOM3MSEnum import *

def State2ProcDef_MDL(self, rootNode, UMLRT2Kiltera_MMRootNode=None):

    # --- Generating attributes code for ASG UMLRT2Kiltera_MM ---
    if( UMLRT2Kiltera_MMRootNode ): 
        # author
        UMLRT2Kiltera_MMRootNode.author.setValue('Annonymous')

        # description
        UMLRT2Kiltera_MMRootNode.description.setValue('\n')
        UMLRT2Kiltera_MMRootNode.description.setHeight(15)

        # name
        UMLRT2Kiltera_MMRootNode.name.setValue('State2ProcDef')
    # --- ASG attributes over ---


    self.obj92=MatchModel(self)
    self.obj92.isGraphObjectVisual = True

    if(hasattr(self.obj92, '_setHierarchicalLink')):
      self.obj92._setHierarchicalLink(False)

    self.obj92.graphClass_= graph_MatchModel
    if self.genGraphics:
       new_obj = graph_MatchModel(60.0,40.0,self.obj92)
       new_obj.DrawObject(self.UMLmodel)
       self.UMLmodel.addtag_withtag("MatchModel", new_obj.tag)
       new_obj.layConstraints = dict() # Graphical Layout Constraints 
       new_obj.layConstraints['scale'] = [1.0, 1.0]
    else: new_obj = None
    self.obj92.graphObject_ = new_obj

    # Add node to the root: rootNode
    rootNode.addNode(self.obj92)
    self.globalAndLocalPostcondition(self.obj92, rootNode)
    self.obj92.postAction( rootNode.CREATE )

    self.obj93=ApplyModel(self)
    self.obj93.isGraphObjectVisual = True

    if(hasattr(self.obj93, '_setHierarchicalLink')):
      self.obj93._setHierarchicalLink(False)

    self.obj93.graphClass_= graph_ApplyModel
    if self.genGraphics:
       new_obj = graph_ApplyModel(60.0,260.0,self.obj93)
       new_obj.DrawObject(self.UMLmodel)
       self.UMLmodel.addtag_withtag("ApplyModel", new_obj.tag)
       new_obj.layConstraints = dict() # Graphical Layout Constraints 
       new_obj.layConstraints['scale'] = [1.0, 1.0]
    else: new_obj = None
    self.obj93.graphObject_ = new_obj

    # Add node to the root: rootNode
    rootNode.addNode(self.obj93)
    self.globalAndLocalPostcondition(self.obj93, rootNode)
    self.obj93.postAction( rootNode.CREATE )

    self.obj94=Element(self)
    self.obj94.isGraphObjectVisual = True

    if(hasattr(self.obj94, '_setHierarchicalLink')):
      self.obj94._setHierarchicalLink(False)

    # classtype
    self.obj94.classtype.setValue('t_')

    # cardinality
    self.obj94.cardinality.setValue('1')

    # name
    self.obj94.name.setValue('s_')

    self.obj94.graphClass_= graph_Element
    if self.genGraphics:
       new_obj = graph_Element(560.0,100.0,self.obj94)
       new_obj.DrawObject(self.UMLmodel)
       self.UMLmodel.addtag_withtag("Element", new_obj.tag)
       new_obj.layConstraints = dict() # Graphical Layout Constraints 
       new_obj.layConstraints['scale'] = [1.0, 1.0]
    else: new_obj = None
    self.obj94.graphObject_ = new_obj

    # Add node to the root: rootNode
    rootNode.addNode(self.obj94)
    self.globalAndLocalPostcondition(self.obj94, rootNode)
    self.obj94.postAction( rootNode.CREATE )

    self.obj95=State(self)
    self.obj95.isGraphObjectVisual = True

    if(hasattr(self.obj95, '_setHierarchicalLink')):
      self.obj95._setHierarchicalLink(False)

    # classtype
    self.obj95.classtype.setValue('t_')

    # cardinality
    self.obj95.cardinality.setValue('1')

    # name
    self.obj95.name.setValue('s_')

    self.obj95.graphClass_= graph_State
    if self.genGraphics:
       new_obj = graph_State(320.0,140.0,self.obj95)
       new_obj.DrawObject(self.UMLmodel)
       self.UMLmodel.addtag_withtag("State", new_obj.tag)
       new_obj.layConstraints = dict() # Graphical Layout Constraints 
       new_obj.layConstraints['scale'] = [1.0, 1.0]
    else: new_obj = None
    self.obj95.graphObject_ = new_obj

    # Add node to the root: rootNode
    rootNode.addNode(self.obj95)
    self.globalAndLocalPostcondition(self.obj95, rootNode)
    self.obj95.postAction( rootNode.CREATE )

    self.obj96=PortType(self)
    self.obj96.isGraphObjectVisual = True

    if(hasattr(self.obj96, '_setHierarchicalLink')):
      self.obj96._setHierarchicalLink(False)

    # classtype
    self.obj96.classtype.setValue('t_')

    # cardinality
    self.obj96.cardinality.setValue('1')

    # name
    self.obj96.name.setValue('s_')

    self.obj96.graphClass_= graph_PortType
    if self.genGraphics:
       new_obj = graph_PortType(780.0,100.0,self.obj96)
       new_obj.DrawObject(self.UMLmodel)
       self.UMLmodel.addtag_withtag("PortType", new_obj.tag)
       new_obj.layConstraints = dict() # Graphical Layout Constraints 
       new_obj.layConstraints['scale'] = [1.0, 1.0]
    else: new_obj = None
    self.obj96.graphObject_ = new_obj

    # Add node to the root: rootNode
    rootNode.addNode(self.obj96)
    self.globalAndLocalPostcondition(self.obj96, rootNode)
    self.obj96.postAction( rootNode.CREATE )

    self.obj97=Def(self)
    self.obj97.isGraphObjectVisual = True

    if(hasattr(self.obj97, '_setHierarchicalLink')):
      self.obj97._setHierarchicalLink(False)

    # classtype
    self.obj97.classtype.setValue('t_')

    # cardinality
    self.obj97.cardinality.setValue('1')

    # name
    self.obj97.name.setValue('s_')

    self.obj97.graphClass_= graph_Def
    if self.genGraphics:
       new_obj = graph_Def(540.0,280.0,self.obj97)
       new_obj.DrawObject(self.UMLmodel)
       self.UMLmodel.addtag_withtag("Def", new_obj.tag)
       new_obj.layConstraints = dict() # Graphical Layout Constraints 
       new_obj.layConstraints['scale'] = [1.0, 1.0]
    else: new_obj = None
    self.obj97.graphObject_ = new_obj

    # Add node to the root: rootNode
    rootNode.addNode(self.obj97)
    self.globalAndLocalPostcondition(self.obj97, rootNode)
    self.obj97.postAction( rootNode.CREATE )

    self.obj98=ProcDef(self)
    self.obj98.isGraphObjectVisual = True

    if(hasattr(self.obj98, '_setHierarchicalLink')):
      self.obj98._setHierarchicalLink(False)

    # classtype
    self.obj98.classtype.setValue('t_')

    # cardinality
    self.obj98.cardinality.setValue('1')

    # name
    self.obj98.name.setValue('s_')

    self.obj98.graphClass_= graph_ProcDef
    if self.genGraphics:
       new_obj = graph_ProcDef(320.0,340.0,self.obj98)
       new_obj.DrawObject(self.UMLmodel)
       self.UMLmodel.addtag_withtag("ProcDef", new_obj.tag)
       new_obj.layConstraints = dict() # Graphical Layout Constraints 
       new_obj.layConstraints['scale'] = [1.0, 1.0]
    else: new_obj = None
    self.obj98.graphObject_ = new_obj

    # Add node to the root: rootNode
    rootNode.addNode(self.obj98)
    self.globalAndLocalPostcondition(self.obj98, rootNode)
    self.obj98.postAction( rootNode.CREATE )

    self.obj99=paired_with(self)
    self.obj99.isGraphObjectVisual = True

    if(hasattr(self.obj99, '_setHierarchicalLink')):
      self.obj99._setHierarchicalLink(False)

    self.obj99.graphClass_= graph_paired_with
    if self.genGraphics:
       new_obj = graph_paired_with(183.0,189.0,self.obj99)
       new_obj.DrawObject(self.UMLmodel)
       self.UMLmodel.addtag_withtag("paired_with", new_obj.tag)
       new_obj.layConstraints = dict() # Graphical Layout Constraints 
    else: new_obj = None
    self.obj99.graphObject_ = new_obj

    # Add node to the root: rootNode
    rootNode.addNode(self.obj99)
    self.globalAndLocalPostcondition(self.obj99, rootNode)
    self.obj99.postAction( rootNode.CREATE )

    self.obj100=match_contains(self)
    self.obj100.isGraphObjectVisual = True

    if(hasattr(self.obj100, '_setHierarchicalLink')):
      self.obj100._setHierarchicalLink(False)

    self.obj100.graphClass_= graph_match_contains
    if self.genGraphics:
       new_obj = graph_match_contains(456.0,111.5,self.obj100)
       new_obj.DrawObject(self.UMLmodel)
       self.UMLmodel.addtag_withtag("match_contains", new_obj.tag)
       new_obj.layConstraints = dict() # Graphical Layout Constraints 
    else: new_obj = None
    self.obj100.graphObject_ = new_obj

    # Add node to the root: rootNode
    rootNode.addNode(self.obj100)
    self.globalAndLocalPostcondition(self.obj100, rootNode)
    self.obj100.postAction( rootNode.CREATE )

    self.obj101=match_contains(self)
    self.obj101.isGraphObjectVisual = True

    if(hasattr(self.obj101, '_setHierarchicalLink')):
      self.obj101._setHierarchicalLink(False)

    self.obj101.graphClass_= graph_match_contains
    if self.genGraphics:
       new_obj = graph_match_contains(566.0,111.5,self.obj101)
       new_obj.DrawObject(self.UMLmodel)
       self.UMLmodel.addtag_withtag("match_contains", new_obj.tag)
       new_obj.layConstraints = dict() # Graphical Layout Constraints 
    else: new_obj = None
    self.obj101.graphObject_ = new_obj

    # Add node to the root: rootNode
    rootNode.addNode(self.obj101)
    self.globalAndLocalPostcondition(self.obj101, rootNode)
    self.obj101.postAction( rootNode.CREATE )

    self.obj102=apply_contains(self)
    self.obj102.isGraphObjectVisual = True

    if(hasattr(self.obj102, '_setHierarchicalLink')):
      self.obj102._setHierarchicalLink(False)

    self.obj102.graphClass_= graph_apply_contains
    if self.genGraphics:
       new_obj = graph_apply_contains(448.0,314.5,self.obj102)
       new_obj.DrawObject(self.UMLmodel)
       self.UMLmodel.addtag_withtag("apply_contains", new_obj.tag)
       new_obj.layConstraints = dict() # Graphical Layout Constraints 
    else: new_obj = None
    self.obj102.graphObject_ = new_obj

    # Add node to the root: rootNode
    rootNode.addNode(self.obj102)
    self.globalAndLocalPostcondition(self.obj102, rootNode)
    self.obj102.postAction( rootNode.CREATE )

    # Connections for obj92 (graphObject_: Obj0) of type MatchModel
    self.drawConnections(
(self.obj92,self.obj99,[182.0, 80.0, 183.0, 189.0],"true", 2),
(self.obj92,self.obj100,[182.0, 80.0, 456.0, 111.5],"true", 2),
(self.obj92,self.obj101,[182.0, 80.0, 566.0, 111.5],"true", 2) )
    # Connections for obj93 (graphObject_: Obj1) of type ApplyModel
    self.drawConnections(
(self.obj93,self.obj102,[184.0, 298.0, 448.0, 314.5],"true", 2) )
    # Connections for obj94 (graphObject_: Obj2) named s_
    self.drawConnections(
 )
    # Connections for obj95 (graphObject_: Obj3) named s_
    self.drawConnections(
 )
    # Connections for obj96 (graphObject_: Obj4) named s_
    self.drawConnections(
 )
    # Connections for obj97 (graphObject_: Obj5) named s_
    self.drawConnections(
 )
    # Connections for obj98 (graphObject_: Obj6) named s_
    self.drawConnections(
 )
    # Connections for obj99 (graphObject_: Obj7) of type paired_with
    self.drawConnections(
(self.obj99,self.obj93,[183.0, 189.0, 184.0, 298.0],"true", 2) )
    # Connections for obj100 (graphObject_: Obj8) of type match_contains
    self.drawConnections(
(self.obj100,self.obj94,[456.0, 111.5, 730.0, 143.0],"true", 2) )
    # Connections for obj101 (graphObject_: Obj9) of type match_contains
    self.drawConnections(
(self.obj101,self.obj96,[566.0, 111.5, 950.0, 143.0],"true", 2) )
    # Connections for obj102 (graphObject_: Obj10) of type apply_contains
    self.drawConnections(
(self.obj102,self.obj97,[448.0, 314.5, 712.0, 331.0],"true", 2) )

newfunction = State2ProcDef_MDL

loadedMMName = 'UMLRT2Kiltera_MM_META'

atom3version = '0.3'
